package com.snail.service;

import com.snail.dto.OrderDto;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

/**
 * @Author 【swg】.
 * @Date 2017/12/8 14:36
 * @DESC
 * @CONTACT 317758022@qq.com
 */
public interface OrderService{
    /**创建订单*/
    OrderDto create(OrderDto orderDto);

    /**根据order_id查询单个订单*/
    OrderDto findOne(String orderid);

    /**查询某个用户的订单列表*/
    Page<OrderDto> findListByOpenid(String openid, Pageable pageable);

    /**取消订单*/
    OrderDto cancel(OrderDto orderDto);

    /**完结订单*/
    OrderDto finish(OrderDto orderDto);

    /**支付订单*/
    OrderDto paid(OrderDto orderDto);

    /**查询所有的订单列表*/
    Page<OrderDto> findList(Pageable pageable);
}
